[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
WAITFOR SEXP,VAR,IEXP
Function
Wait for a specific string of text to come in from the modem.
(WAIT FOR is a synonym).
Syntax
WAITFOR str,flag,sec
str - Any string expression.
flag - A variable to return the status.
sec - An integer expression with the maximum number of seconds to wait.
Remarks
This statement can be used to wait for specific replies to questions,
responses from terminal emulators and modem result codes. If the text
that is needed isn't received within the specified time period, or if
there is not a remote caller online, flag will be set to FALSE. If the
text is found, then flag will be TRUE. If a remote caller is online this
statement will wait up to the maximum time for the text and return TRUE
or FALSE as appropriate. If the caller is local, it will immediately
return FALSE. Also, the text to wait for is not case sensitive.
"connect" will match "CONNECT".
Examples
BOOLEAN flag
KBDCHKOFF
CDCHKOFF
DTROFF
DELAY 18
DTRON
SENDMODEM "ATDT5551212" ' Please don't really dial this number!
WAITFOR "CONNECT",flag,60
IF (!flag) SPRINLN "No connect found in 60 seconds"
CDCHKON
KBDCHKON
See Also:
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson